# coding: utf-8
from qfluentwidgets import FluentIconBase, Theme, getIconColor
from enum import Enum
from .settings import ICONS_DIR, SINGLE_DIR


class Icon(FluentIconBase, Enum):
    MIN = 'min'
    MAX = 'max'
    CLOSE = 'close'
    NORMAL = 'normal'
    HOME = 'home'
    TOP_SHOW = 'top_show'
    TOP_SHOW_FULL = 'top_show_full'

    def path(self, theme=Theme.AUTO) -> str:
        return (ICONS_DIR / f'{self.value}_{getIconColor(theme)}.svg').as_posix()


class SingleIcon(FluentIconBase, Enum):
    LOGO = 'Logo.png'
    QS_LOGO = 'qs_logo_white.png'
    AUTH_LEFT_IMG = 'auth_left_img.png'
    COVER = 'Cover.png'

    def path(self, theme=Theme.AUTO) -> str:
        return (SINGLE_DIR / self.value).as_posix()
